﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace UCHENG.FILEHASH.UTILS
{
    public class MessageService
    {

        /// <summary>
        /// 启动
        /// </summary>
        /// <param name="playerCode"></param>
        /// <param name="playerVersion"></param>
        public static void launch(string playerCode, string playerVersion)
        {
            Console.WriteLine(String.Format("播放器 : "));
        }

        /// <summary>
        /// 下载开始
        /// </summary>
        /// <param name="name"></param>
        public static void start(string name)
        {
            Console.WriteLine(String.Format("文件：{0}", name));
            Console.WriteLine(String.Format("时间：{1} 开始下载>>>>", name, DateTime.Now.ToString("yyyy-MM-dd hh:mm:ss")));
        }


        /// <summary>
        /// 下载过程
        /// </summary>
        /// <param name="value"></param>
        public static void process(string value)
        {
            Console.WriteLine(String.Format("{0}%", value));
        }

        /// <summary>
        /// 下载完成
        /// </summary>
        /// <param name="name"></param>
        public static void end(string name, double totalSeconds)
        {
            Console.WriteLine(String.Format("文件：{0} 完成下载! ", name));
            Console.WriteLine(String.Format("时间：{0}  耗时：{1}秒", DateTime.Now.ToString("yyyy-MM-dd hh:mm:ss"), totalSeconds));
        }


        public static void start_unzip(string name)
        {
            Console.WriteLine(String.Format("文件：{0}", name));
            Console.WriteLine(String.Format("时间：{0} 开始解压>>>>", DateTime.Now.ToString("yyyy-MM-dd hh:mm:ss")));
        }

        public static void end_unzip(string name, double totalSeconds)
        {
            Console.WriteLine(String.Format("文件：{0} 完成解压!", name));
            Console.WriteLine(String.Format("时间：{0}  耗时：{1}秒", DateTime.Now.ToString("yyyy-MM-dd hh:mm:ss"), totalSeconds));
        }

        public static void readLine()
        {
            Console.ReadLine();
        }


        //目录重命名
    }
}
